# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=kdav
pkgver=5.73.0
pkgrel=0
pkgdesc="A DAV protocol implementation with KJobs"
url="https://community.kde.org/Frameworks"
arch="all !armhf" # armhf blocked by qt5-qtdeclarative
license="LGPL-2.0-or-later"
depends_dev="qt5-qtbase-dev qt5-qtxmlpatterns-dev kcoreaddons-dev kio-dev ki18n-dev"
makedepends="$depends_dev extra-cmake-modules doxygen qt5-qttools-dev"
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang"
source="https://download.kde.org/stable/frameworks/${pkgver%.*}/kdav-$pkgver.tar.xz"

build() {
	cmake -B build \
		-DCMAKE_BUILD_TYPE=None \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib \
		-DBUILD_QCH=ON
	cmake --build build
}

check() {
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --build build --target install
}

sha512sums="1617fe65dd90f119f5181be7f234787eb43bb3a90e73b78503c45a3b1a843e3c8078b1cbfde97781fb7a531d987536662126e3eab41014bc18f05b7b0caa0ca1  kdav-5.73.0.tar.xz"
